package com.guonl.controller;

import com.guonl.model.TipsModel;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

/**
 * Created by nianlei.guo on 2017/12/12.
 */
@RestController
@RequestMapping("/springboot")
public class UserController {

    @Autowired
    private TipsModel tips;

    @ResponseBody
    @RequestMapping(value = "/{name}", method = RequestMethod.GET)
    public String sayWorld(@PathVariable("name") String name) {
        System.out.println(tips.toString());
        return "Hello " + name;
    }
}
